package com.hf.lookatme.utils;

import android.os.Environment;

/**
 * Created by JoeShiguang on 2015/5/22.
 */
public class SDCardUtils {

  public static String getSDCartPath() {
    String SDCardPath = null;
    if (isMount()) {// 确认sdcard的存在
      SDCardPath = Environment.getExternalStorageDirectory().getAbsolutePath();
    }
    return SDCardPath;
  }

  // 确认sdcard的存在
  private static boolean isMount() {
    String SDState = Environment.getExternalStorageState();
    return Environment.MEDIA_MOUNTED.equals(SDState);
  }
}
